package com.sleepsocial.logging;

import java.util.logging.Level;

public class Logger {
    private final java.util.logging.Logger logger;

    private Logger(String name) {
        logger = java.util.logging.Logger.getLogger(name);
    }

    public static Logger getInstance(String name) {
        return new Logger(name);
    }

    public void i(String message) {
        logger.log(Level.INFO, message);
    }

    public void i(String message, Throwable e) {
        logger.log(Level.INFO, message, e);
    }

    public void d(String message) {
        logger.log(Level.FINE, message);
    }

    public void d(String message, Throwable e) {
        logger.log(Level.FINE, message, e);
    }

    public void w(String message) {
        logger.log(Level.WARNING, message);
    }

    public void w(String message, Throwable e) {
        logger.log(Level.WARNING, message, e);
    }

    public void e(String message) {
        logger.log(Level.SEVERE, message);
    }

    public void e(String message, Throwable e) {
        logger.log(Level.SEVERE, message, e);
    }

}
